<HTML> 
<HEAD> 
	<TITLE>3rd Party ROBOTC Drivers</TITLE> 
<link href="tabs.css" rel="stylesheet" type="text/css"/> 
<link href="doxygen.css" rel="stylesheet" type="text/css"/> 
</HEAD> 
 
<BODY bgcolor="#ffffff" link="#000000" vlink="#000000"> 
<table width="100%" bgcolor="navy" cellspacing=0 cellpadding=1 border=0> 
<tr><td><table width="100%" bgcolor="#EEEEDD" cellspacing=0 cellpadding=3 border=0> 
<tr> 
    <td width="33%" align="left"> <img src="images/LOGO_NXT.gif" width=266 height=44 border="0" alt="Mindstorms"></td> 
    <td><b><font size="+3" color="navy">3rd Party ROBOTC Drivers</font></b></td> 
    <td align="right"> <img src="images/logo.png" width=44 height=44 border="0" alt="RobotC"></td>     
</tr> 
  <tr bgcolor="#cccc99" align="right"> 
          <td colspan=3> <font face="arial" size="-1"> [<a href=main.html>Home</a>] [<a target=_top href="https://sourceforge.net/projects/rdpartyrobotcdr/">Download</a>] [<a target=_top href="http://apps.sourceforge.net/mantisbt/rdpartyrobotcdr/my_view_page.php">Submit a bug/suggestion</a>]  [<a target=_top href="http://www.robotc.net/forums/">ROBOTC Forums</a>] [<a target=_top href="http://botbench.com">Blog</a>] [<a target=_top href="http://sourceforge.net/donate/index.php?group_id=257238">Support this project</a>]</font> </td> 
</tr> 
</table></td></tr> 
</table> 
<!-- Generated by Doxygen 1.7.2 -->
<div class="header">
  <div class="summary">
<a href="#define-members">Defines</a> &#124;
<a href="#func-members">Functions</a> &#124;
<a href="#var-members">Variables</a>  </div>
  <div class="headertitle">
<h1>hitechnic-colour-v1.h File Reference</h1>  </div>
</div>
<div class="contents">

<p>HiTechnic Color Sensor driver.  
<a href="#_details">More...</a></p>
<code>#include &quot;<a class="el" href="common_8h_source.html">common.h</a>&quot;</code><br/>
<code>#include &quot;<a class="el" href="common-light_8h_source.html">common-light.h</a>&quot;</code><br/>

<p><a href="hitechnic-colour-v1_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="define-members"></a>
Defines</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga2a76ad0892f996cc7178faaf9791f192">HTCS_I2C_ADDR</a>&#160;&#160;&#160;0x02</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gae677f5ade0fb6cf293a3c05a19130b45">HTCS_CMD_REG</a>&#160;&#160;&#160;0x41</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gae484aed41a5751ac670d59b93c381ef6">HTCS_OFFSET</a>&#160;&#160;&#160;0x42</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga48031d09dc69fa4ddeeaa5048b0cc7b6">HTCS_COLNUM_REG</a>&#160;&#160;&#160;0x00</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gadfe281ee2acf1c368a01f11c9ced2301">HTCS_RED_REG</a>&#160;&#160;&#160;0x01</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga2bc065e0ae0c88b3a2274b2f2c5029ab">HTCS_GREEN_REG</a>&#160;&#160;&#160;0x02</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gac6e1008ac54bd796727bb2b024c94b5c">HTCS_BLUE_REG</a>&#160;&#160;&#160;0x03</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga231348f4db7df4344265d3cfe43f8cba">HTCS_RED_RAW_REG</a>&#160;&#160;&#160;0x04</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gafbcd3ba05b2d2cd43a4846dc7fdb9718">HTCS_GREEN_RAW_REG</a>&#160;&#160;&#160;0x05</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gaee2f2c7a03a73d2795e10e41f8b30a04">HTCS_BLUE_RAW_REG</a>&#160;&#160;&#160;0x06</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga86e23f552e2b245ab759832545c65e69">HTSC_COL_INDEX_REG</a>&#160;&#160;&#160;0x07</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga63ecff1a93442ac51d80d87b3ef2a31d">HTSC_RED_NORM_REG</a>&#160;&#160;&#160;0x08</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga674677aff9b035ad76b8aa7088d80614">HTSC_GREEN_NORM_REG</a>&#160;&#160;&#160;0x09</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga78d88dda248094bc368357c17a744677">HTSC_BLUE_NORM_REG</a>&#160;&#160;&#160;0x0A</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga55a7e1240a43a39633d65c210ed0f921">HTCS_CAL_WHITE</a>&#160;&#160;&#160;0x43</td></tr>
<tr><td colspan="2"><h2><a name="func-members"></a>
Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga2ffe78205a159ffd11e8074665c293dc">HTCSreadColor</a> (tSensors link)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga4de07d555366975fb0673524cdec7b57">HTCSreadRGB</a> (tSensors link, int &amp;red, int &amp;green, int &amp;blue)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gac07b9f4043e6abbd7d80785afb1e0e6d">HTCSreadNormRGB</a> (tSensors link, int &amp;red, int &amp;green, int &amp;blue)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gae17b52a255db2290b22bc25fb966eed1">HTCSreadRawRGB</a> (tSensors link, int &amp;red, int &amp;green, int &amp;blue)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga850041d1cce06d2fe714780bba407040">HTCScalWhite</a> (tSensors link)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga38b8b7f82814d32cba3d6a6f54a85a85">HTCSreadColor</a> (<a class="el" href="group__htsmux.html#gab5bad1759ac110c43e66c3ec54047f42">tMUXSensor</a> muxsensor)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga0cc4cf1c6fc26e88fc7a708857ef7ca2">HTCSreadRGB</a> (<a class="el" href="group__htsmux.html#gab5bad1759ac110c43e66c3ec54047f42">tMUXSensor</a> muxsensor, int &amp;red, int &amp;green, int &amp;blue)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga27de3044e46a7fc9dda2602617559928">HTCSreadHSV</a> (tSensors link, float &amp;hue, float &amp;saturation, float &amp;value)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga94042640abb264c85f8c030581e2eacf">HTCSreadHSV</a> (<a class="el" href="group__htsmux.html#gab5bad1759ac110c43e66c3ec54047f42">tMUXSensor</a> muxsensor, float &amp;hue, float &amp;saturation, float &amp;value)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#gac44edcceb5417b277cfe77a795bee8f1">HTCSreadColorIndex</a> (tSensors link)</td></tr>
<tr><td colspan="2"><h2><a name="var-members"></a>
Variables</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__htsmux.html#gae535601c6d1a8544ed23e79d545ce45c">tConfigParams</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga893e1213ff25f453ddaf5459a46e1741">HTCS_config</a> = {HTSMUX_CHAN_I2C, 4, 0x02, 0x42}</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__common.html#gaa172ef131853460e5b9f5c6db81d30f4">tByteArray</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga41f32070b6744358c9a81806f6552828">HTCS_I2CRequest</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__common.html#gaa172ef131853460e5b9f5c6db81d30f4">tByteArray</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__htcs.html#ga755eeaa1ceaec836d19810e9fd7dc8c0">HTCS_I2CReply</a></td></tr>
</table>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<p>HiTechnic Color Sensor driver. </p>
<p><a class="el" href="hitechnic-colour-v1_8h.html" title="HiTechnic Color Sensor driver.">hitechnic-colour-v1.h</a> provides an API for the HiTechnic Color Sensor driver.</p>
<p>Changelog:</p>
<ul>
<li>0.1: Initial release</li>
<li>0.2: Added SMUX functions</li>
<li>0.3: All functions that uses tIntArray are now pass by reference to reduce memory usage.<br/>
 Removed SMUX data array</li>
<li>0.4: Use new calls in <a class="el" href="common_8h.html" title="Commonly used functions used by drivers.">common.h</a> that don't require SPORT/MPORT macros <br/>
 Removed calls to ubyteToInt()</li>
<li>0.5: Replaced array structs with typedefs</li>
</ul>
<p>Credits:</p>
<ul>
<li>Big thanks to HiTechnic for providing me with the hardware necessary to write and test this.</li>
</ul>
<p>License: You may use this code as you wish, provided you give credit where its due.</p>
<p>THIS CODE WILL ONLY WORK WITH ROBOTC VERSION 3.59 AND HIGHER.</p>
<dl class="author"><dt><b>Author:</b></dt><dd>Xander Soldaat (xander_at_botbench.com) </dd></dl>
<dl class="date"><dt><b>Date:</b></dt><dd>20 February 2011 </dd></dl>
<dl class="version"><dt><b>Version:</b></dt><dd>0.5 </dd></dl>

<p>Definition in file <a class="el" href="hitechnic-colour-v1_8h_source.html">hitechnic-colour-v1.h</a>.</p>
</div>
<hr class="footer"/><address class="footer"><small>Generated on Wed Mar 13 2013 19:56:43 for ROBOTC Drivers by&#160;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.2 </small></address>
</body>
</html>
